<script setup lang="ts">
import ElFormItemWrapper from "./components/ElFormItemWrapper.vue";
import {defineComponent, ref} from "vue";

const fieldModel = ref(null)

defineComponent({
  name: 'custom-el-radio-group'
})
defineProps({
  field: Object,
  activeItem: Object
})
</script>

<template>
  <ElFormItemWrapper :field="field" :activeItem="activeItem">
    <el-radio-group v-model="fieldModel" :placeholder="field?.options.placeholder">
      <el-radio v-for="(item, index) in field?.options.optionItems" :key="index" :label="item.value">{{ item.label }}</el-radio>
    </el-radio-group>
  </ElFormItemWrapper>
</template>

<style scoped>

</style>
